<!DOCTYPE html>
<html>

<head>
    <!-- 页面meta -->
    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <title>知识库</title>
    <!-- Tell the browser to be responsive to screen width -->
    <meta content="width=device-width,initial-scale=1,maximum-scale=1,user-scalable=no" name="viewport">
  
    <link rel="stylesheet" href="../plugins/bootstrap/css/bootstrap.min.css">
    <link rel="stylesheet" href="../plugins/adminLTE/css/AdminLTE.css">
    <link rel="stylesheet" href="../plugins/adminLTE/css/skins/_all-skins.min.css">
    <link rel="stylesheet" href="../css/style.css">
	<script src="../plugins/jQuery/jquery-2.2.3.min.js"></script>
    <script src="../plugins/bootstrap/js/bootstrap.min.js"></script>
    
    <!-- 富文本编辑器 -->
	<link rel="stylesheet" href="../plugins/kindeditor/themes/default/default.css" />
	<script charset="utf-8" src="../plugins/kindeditor/kindeditor-min.js"></script>
	<script charset="utf-8" src="../plugins/kindeditor/lang/zh_CN.js"></script>
    <script src="../js/vuejs-2.5.16.js"></script>
    <script src="../js/axios-0.18.0.js"></script>
    <script src="../js/vue-select.js"></script>
</head>
<body class="hold-transition skin-red sidebar-mini">
<div id="app">

            <!-- 正文区域 -->
            <section class="content">

                <div class="box-body">

                    <!--tab页-->
                    <div class="nav-tabs-custom">

                        <!--tab头-->
                        <div class="nav nav-tabs">
                              新建文章
                        </div>
                        <!--tab头/-->
						
                        <!--tab内容-->
                        <div class="tab-content" >

                            <!--表单内容-->
                            <div class="tab-pane active" id="home">
                                <div class="row data-type">                                  
								   <div class="col-md-2 title">文章分类</div>
		                          
		                           	  <div class="col-md-10 data">
		                           	  	<table>
                                            <tr>
                                                <td>
                                                    <select class="form-control" v-model="category1Id">
                                                        <!--<option v-for="itemCat in itemCatList1" :value="itemCat.id">{{itemCat.name}}</option>-->
                                                        <option v-for="cate in categoryList" :value="cate.id">{{cate.categoryName}}</option>
                                                    </select>
                                                </td>
                                                <td>
                                                    <select class="form-control" v-model="entity.categoryId">
                                                        <option v-for="cate in category2List" :value="cate.id" >{{cate.categoryName}}</option>
                                                    </select>
                                                </td>
                                            </tr>
		                           	  	</table>
		                              	
		                              </div>

                                   <div class="col-md-2 title">标题</div>
                                    <div class="col-md-10 data">
                                        <input type="text" v-model="entity.title" class="form-control" placeholder="文章标题"
                                               value="">
                                    </div>

                                    <div class="col-md-2 title editer">正文</div>
                                    <div class="col-md-10 data editer" >
                                <textarea name="content" v-model="entity.article"
                                          style="width:965px;height:480px;visibility:hidden"></textarea>
                                    </div>


                                </div>
                            </div>

                        </div>
                        <!--tab内容/-->
						<!--表单内容/-->
							 
                    </div>
                 	
                 	
                 	
                 	
                   </div>
                  <div class="btn-toolbar list-toolbar">
				      <button class="btn btn-primary" @click="save()"><i class="fa fa-save"></i>保存</button>
                      <button onclick="parent.window.location.reload()" class="btn btn-default">返回列表</button>
				  </div>
			
            </section>
            
</div>
<script type="text/javascript">

    var editor;
    KindEditor.ready(function(K) {
        editor = K.create('textarea[name="content"]', {
            allowFileManager : true,
            filePostName:"file",
            uploadJson:'/upload/kindUpload.do',
            fileManagerJson:'/upload/findAllPic.do'
        });
    });

</script>
</body>
<script type="text/javascript" src="../js/controller/content_edit.js"></script>
</html>